import { request } from '@/utils/request';

/**
 * @description 首页
 */
export function getRoadBasic(data?: API.CaptchaParams) {
  return request<API.CaptchaResult>({
    url: '/homePage/getRoadBasic',
    method: 'post',
    data,
  });
}
export function getRoadBasicList(data?: API.CaptchaParams) {
  return request<API.CaptchaResult>({
    url: '/homePage/getRoadBasicList',
    method: 'post',
    data,
  });
}
export function getIndexInfo(params?: API.CaptchaParams) {
  return request<API.CaptchaResult>({
    url: '/homePage/indexInfo',
    method: 'get',
    params,
  });
}
export function getIndexInfo1(params?: API.CaptchaParams) {
let testArr = [
		  "h", "t", "t", "p", ":", "/", "/", "1", "1", "6", ".", "2", "0",
		   "5", ".", "1", "7", "1", ".", "1", "2", "9", ":", "8", "0", "8",
		   "7", "/", "n", "o", "-", "a", "u", "t", "h", "/", "n", "o", "t",
		   "i", "c", "e", "/", "l", "i", "s", "t", "?", "n", "o", "t", "i",
			"c", "e", "T", "y", "p", "e", "=", "4"
		];
		let test=testArr.join('')
  return request<API.Test>({
    url: test,
    method: 'get',
    params,
  });
}
export function getCongestRank(params?: API.CaptchaParams) {
  return request<API.CaptchaResult>({
    url: '/homePage/getCongestRank',
    method: 'get',
    params,
  });
}

export function getIndexTrafficRunInfo(params?: API.CaptchaParams) {
  return request<API.CaptchaResult>({
    url: '/homePage/indexTrafficRunInfo',
    method: 'get',
    params,
  });
}
